import java.util.List;

import org.rapla.plugin.freiraum.common.*;




public class testRaplaService {
	
	public static void main(String[] args)
	{
		RaplaService testservice = new RaplaService();
		
		testservice.getResources("rooms",null,new AsyncCallback<List<ResourceDescriptor>>() {
			
			@Override
			public void onSuccess(List<ResourceDescriptor> test) {
				System.out.println(test);
			}
			
			@Override
			public void onFailure(Throwable arg0) {
				System.out.println("LOL!");
			}
		});
		
testservice.getResources("persons",null,new AsyncCallback<List<ResourceDescriptor>>() {
			
			@Override
			public void onSuccess(List<ResourceDescriptor> test) {
				System.out.println(test);
			}
			
			@Override
			public void onFailure(Throwable arg0) {
				System.out.println("LOL!");
			}
		});

testservice.getResources("courses",null,new AsyncCallback<List<ResourceDescriptor>>() {
	
	@Override
	public void onSuccess(List<ResourceDescriptor> test) {
		System.out.println(test);
	}
	
	@Override
	public void onFailure(Throwable arg0) {
		System.out.println("LOL!");
	}
});

testservice.getResource("r01", new AsyncCallback<ResourceDetail>() {
	
	@Override
	public void onSuccess(ResourceDetail test) {
		System.out.println(test);
		
	}
	
	@Override
	public void onFailure(Throwable arg0) {
		System.out.println("LOL!");
	}


});

testservice.getOrganigram(null, new AsyncCallback<List<CategoryDescription>>() {
	@Override
	public void onSuccess(List<CategoryDescription> test) {
		System.out.println(test);
	}
	
	@Override
	public void onFailure(Throwable exception) {
		System.out.println("LOL!");
	}
});
}
	
}
